#!/bin/sh
###
 # @Author: jmdvirus ciyingjue@163.com
 # @Date: 2024-07-12 11:14:11
 # @LastEditors: jmdvirus ciyingjue@163.com
 # @LastEditTime: 2024-07-12 11:22:32
 # @FilePath: /ai/img_split_mark.sh
 # @Description: 
### 

src=release_data/img_mark
dst=release_data/img_split

dst_img=$dst/images
dst_json=$dst/labels

mkdir -p $dst_img
mkdir -p $dst_json

for file in $(ls $src)
do
    postfix=${file##*.}
    echo "file : $file, ext: $postfix"
    if [ x"$postfix" == x"json" ]; then
        echo "cp $src/$file $dst_json"
        cp $src/$file $dst_json
    else
        echo "cp $src/$file $dst_img"
        cp $src/$file $dst_img
    fi
done
